<script setup>
import Child from './Child.vue'

const handlerClick=(message)=>{
    console.log(message)
}
</script>

<template>
    <div>
        <h1>父组件</h1>
        <p>这是父组件页面</p>
        <my-com prop-name="来自父组件的消息"></my-com>
        <child @custom-event="handlerClick"></child>
    </div>
</template>